<template>
    <div class="app-container">
        <!-- 用户基础信息 -->
        <h5 class="titleInfo">
            用户基础信息
        </h5>
        <el-form ref="list1" :inline="true" :model="list1" label-width="130px">
            <el-row>
                <el-col :span="12">
                    <el-form-item label="用户姓名">
                        <span class="spanToInput">{{list1.username | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="手机号">
                        <span class="spanToInput">{{list1.nickName | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="服务商姓名">
                        <span class="spanToInput">{{list1.realname | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="服务商手机号">
                        <span class="spanToInput">{{list1.sex | filterNull}}</span>
                    </el-form-item>
                </el-col>
            </el-row>
        </el-form>
        <!-- 项目订单基础信息 -->
        <div class="divBar"></div>
        <h5 class="titleInfo">
            项目订单基础信息
        </h5>
        <el-form ref="list1" :inline="true" :model="list1" label-width="130px">
            <el-row>
                <el-col :span="12">
                    <el-form-item label="订单号">
                        <span class="spanToInput">{{list1.refereeName | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="订单下单时间">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="订单状态">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="订单支付时间">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="支付方式">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="订单应付金额">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="抵扣积分">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="优惠券抵扣">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="订单支付金额">
                        <span class="spanToInput">{{list1.referee | filterNull}}</span>
                    </el-form-item>
                </el-col>
            </el-row>
        </el-form>
        <!-- 项目预约信息 -->
        <div class="divBar"></div>
        <h5 class="titleInfo">
            项目预约信息
        </h5>
        <el-form ref="list1" :inline="true" :model="list1" label-width="130px">
            <el-row>
                <el-col :span="12">
                    <el-form-item label="预约单号">
                        <span class="spanToInput">{{list1.identityType | cardNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="医院名称">
                        <span class="spanToInput">{{list1.identity | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="项目名称">
                        <span class="spanToInput">{{list1.identity | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="预约日期">
                        <span class="spanToInput">{{list1.identity | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="咨询结果">
                        <span class="spanToInput">{{list1.identity | filterNull}}</span>
                    </el-form-item>
                </el-col>
            </el-row>
        </el-form>
        <!-- 项目退款信息 -->
        <div class="divBar"></div>
        <h5 class="titleInfo">
            项目退款信息
        </h5>
        <el-form ref="list" :inline="true" :model="list3" label-width="130px">
            <el-row>
                <el-col :span="12">
                    <el-form-item label="退款时间">
                        <span class="spanToInput">{{list3.disposition | filterNull}}</span>
                    </el-form-item>
                </el-col>
                <el-col :span="12">
                    <el-form-item label="退款说明">
                        <span class="spanToInput">{{list3.focus | userFocus}}</span>
                    </el-form-item>
                </el-col>
            </el-row>
        </el-form>
    </div>
</template>
<script>
    import { vipInfo } from '@/api/vipInfo' 
    export default {
        name:"itemOrderInfo",
        data(){
            return {
                userId:"",
                list1:{},
                list2:[],
                list3:{}
            }
        },
        filters:{
            filterNull(e) {
                if(!e){
                    return "暂无"
                }else{
                    return e
                }
            },
            cardNull(e){
                return window.helper.cardType(e)
            },
            userFocus(e){
                return window.helper.userFocus(e)
            }
        },
        mounted(){
            this.userId = Number(this.$route.query.userId)
            this.getList()
        },
        methods:{
            getList(){
                let datas = {userId:this.userId}
                // vipInfo(datas).then().then(res =>{
                //     console.log(res)
                //     if(!res.data.code){
                //         if(res.data.data.user){
                //             this.list1 = res.data.data.user
                //         }
                //         if(res.data.data.bankCard){
                //             this.list2 = res.data.data.bankCard
                //         }
                //         if(res.data.data.userExtra){
                //             this.list3 = res.data.data.userExtra
                //         }
                //     }else{
                //         this.$message.error("数据接口访问失败");
                //     }
                // })
                // .catch(error =>{
                //     this.$message.error(error);
                // })
            }
        }
    }
</script>

<style scoped>
    .app-container{padding: 0px!important}
    .form{margin-left: 268px}
</style>